Skip to content

feat(video3d): bind Scene3D slots with durable dual-origin refs - #227

Merged
IAnMove merged 1 commit into
developmentfrom
grok/agente2-scene3d-aodwwtcm
Sep 7, 2026
Merged

feat(video3d): bind Scene3D slots with durable dual-origin refs#227
IAnMove merged 1 commit into
developmentfrom
grok/agente2-scene3d-aodwwtcm

Conversation

@IAnMove

@IAnMove IAnMove commented Sep 7, 2026

Copy link
Copy Markdown
Owner

Summary

G2-F: Scene3D slots (S3D-01..04, including drive/cafe roles) use shared AssetInput (From my computer / From HocusPocus).

  • Local files upload once via existing AssetInput; the document stores the returned URL, not a blob:.
  • Catalog picks keep workspaceId + filename (+ optional assetId if present).
  • Cancel/clear is explicit; template/workspace/generation mismatch and export lock (fix(video3d): no mezclar el MP4 si se cambia la escena a mitad de export #216) ignore late applies.
  • S3D-05 (loaded GLB clips) stays a local <select>, not the picker.

Does not edit picker core (asset-picker/, StudioSourceField). Agent1 G1-C0 may later attach catalog ids; this already forwards id when ApiOutput has one.

Do not merge until asked.

IDs

S3D-01..04. Templates re-counted after #204/#212 (cafe-dance, drive-*).

Base / HEAD

Test plan

  • ui/tests/scene3dSlotSource.test.mjs + scene3dStage.test.mjs — 22 passed (lock RAM, concurrency 1)
  • GitHub UI lint/typecheck/build/e2e

Limits

No GPU, no live GLB visual QA, no full local tsc -b.


Note

Medium Risk
Changes how scene documents store asset bindings and when async picker commits apply; incorrect guards could drop valid selections or leave stale refs, but scope is limited to Scene3D workspace UI and parsing.

Overview
Scene3D slot sourcing moves from a modal explorer plus raw file input to the shared AssetInput (local upload and workspace catalog), with slot media still constrained by role (images for background, .glb models elsewhere).

Slot assignments now persist durable sourceUrl values and an optional sourceRef (workspaceId, filename, URL, optional assetId) via new slotSource helpers. blob: / filesystem: URLs are rejected on commit and stripped on document parse so saved scenes do not keep ephemeral sources. commitSlotSourceChoice applies or clears bindings only when generation, template, workspace, and slot still match, and ignores changes while export is locked; template switches, workspace changes, and agent workflow loads bump a generation counter to drop stale picker callbacks.

Workspace-scoped model and image lists are prefetched for the picker. Loaded GLB clip selection remains the existing local <select>, unchanged.

Reviewed by Cursor Bugbot for commit d2feff2. Configure here.

Replace blob object URLs and the ad-hoc explorer with AssetInput so
local files upload once and catalog picks keep workspace+filename.
Late choices after template/workspace change or during export are ignored.
@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown

PR Review — Loreframe Studio

Risk: low
Scope: 6 file(s); +283/-50; React UI

Automated review from scripts/analyze_pr.py. This is a heuristic pass (no LLM) so humans still own the merge decision.

Findings

  • low — UI changed — rebuild before merge
    Run cd ui && npm run build (CI already does this). Pinokio Update rebuilds for end users; keep ui/dist untracked.

Changed files

  • added: ui/src/features/scene3d/slotSource.ts, ui/tests/scene3dSlotSource.test.mjs
  • modified: ui/src/features/scene3d/Scene3DWorkspace.tsx, ui/src/features/scene3d/document.ts, ui/src/features/scene3d/templates.ts, ui/src/features/scene3d/types.ts

CONTRIBUTING checklist

  • python scripts/verify_clean_repo.py
  • python -m compileall -q app/services app/launch.py scripts
  • cd ui && npm run build if the UI changed
  • No weights, CivitAI sidecars, or generated guides
  • Stays local-first (no required accounts / telemetry)

Posted by the repo PR review workflow. Re-runs on each push to the PR.

@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown

Code health

Quality score: 54.3/100

Higher is better. The score is a trend dashboard; the independent ratchet below remains the CI gate.

Component Weight Current Change
Cyclomatic health 45% 54.3 +0.0
File concentration 25% 60.9 +0.0
Oversized-file debt 20% 36.4 +0.1
Modularity 10% 73.2 +0.1

Change vs PR base: +0.1 points.

Metric Value
Production LOC 262,130
Production files 674
Test LOC 90,905
Functions measured 16,809
Functions complexity ≥ 15 824
Maximum complexity 670
Policy code-health-policy-v1
HEAD 6b2fa14ba343e952206cd9fe9364ee0d6dd79e99
Base a8cabea4f7bb2a0b2f8034640fc5b0390eb01ca9
UI measurement complete

Markdown, JSON catalogs and tests are out of this table. Only app/ runtime + ui/src TS/JS count.

Most complex functions

Complexity Where
670 app/wgp.py:7164 generate_video
376 ui/src/stores/useStore.ts:4029 Async method 'startGeneration'
355 app/_launch_runtime.py:23505 _run_generation
308 app/wgp.py:12298 generate_video_tab
271 ui/src/stores/useStore.ts:8572 Async method 'loadSettingsFromOutput'
258 app/services/director/planners/short_film.py:3433 ShortFilmPlanner._plan_story_driven
257 ui/src/components/Sidebar/SceneAnimatorPanel.tsx:478 Function 'SceneAnimatorPanel'
248 app/services/director_pipeline.py:13607 _run_video_generation
245 app/services/director_pipeline.py:7712 _run_pipeline
244 ui/src/features/agent/agentActions.ts:1145 Function 'parseAction'
226 app/services/director_pipeline.py:6541 update_comic_preview
225 ui/src/features/agent/agentActions.ts:2892 Async function 'executeAgentActions'

Trend vs baseline

Metric Δ
Production LOC +145
Test LOC +88
Functions ≥ 15 +0
Maximum complexity +0

Warnings

  • production LOC increased by +145

Ratchet passed.

@IAnMove
IAnMove marked this pull request as ready for review September 7, 2026 19:18
@IAnMove
IAnMove merged commit f91b2a6 into development Sep 7, 2026
10 checks passed
@cursor

cursor Bot commented Sep 7, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_aef89687-3718-4b98-9a47-3619637c4890)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant